Skip to content

Added Registration #41

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 3, 2017
Merged

Added Registration #41

merged 1 commit into from
Jul 3, 2017

Conversation

vaibhavsingh97
Copy link
Member

fixes #25
Screenshot after fix:
image
image
image
image

@vaibhavsingh97
Copy link
Member Author

@tapasweni-pathak @nikhita @jarifibrahim Please review

Copy link
Member

@jarifibrahim jarifibrahim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vaibhavsingh97 This is a huge pull request. You should never make these many changes in one PR. Always try to make atomic commits. :)

One more thing you should be careful about is the indentation settings in your IDE. I believe most of the changes in this PR have been made by the auto-format feature of the IDE.

BTW, I pulled your code and ran it locally. The registration and login process doesn't seem to work.
Please fix it. We cannot merge untill it works.

You just need to make some minor changes then we can merge your code. Good job :)

@@ -0,0 +1,7 @@
<component name="InspectionProjectProfileManager">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file is generated by Pycharm and you shouldn't add it.

Please remove this file and all the files in the .idea directory.

transition: opacity 0.7s ease-in-out;
font-family: "Montserrat", sans-serif
padding: 0;
margin: 0;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most of the changes in this file are related to indentation. Please undo these indentation changes. It's preferable to use a tab size of 2 spaces in css files.

<span class="col-sm-6 left-align">
<li>
<a href="https://www.facebook.com/opensourcehelpcommunity/"><i class="fa fa-facebook" aria-hidden="true"></i></a>
<a href="https://www.facebook.com/opensourcehelpcommunity/"><i
Copy link
Member

@jarifibrahim jarifibrahim Jun 28, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix indentation.

</form>

{% else %}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary new line.

@@ -20,11 +22,10 @@
SECRET_KEY = 'x1-pogt0-b5owbgq0=ui02-4v)bba!bg&1m8_$)8-&13(907qf'

# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = os.getenv("DEBUG", False)
DEBUG = os.getenv("DEBUG", True)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DEBUG should be set to False.

@@ -105,3 +120,12 @@
STATICFILES_DIRS = (
os.path.join(BASE_DIR, 'main/'),
)

EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
EMAIL_USE_TLS = True
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change this and following lines to os.getEnv('EMAIL_USE_TLS). This way it is easier to change the email server and related settings.

</div>
</div>
</nav>
<nav class="navbar navbar-inverse navbar-static-top navbar-fixed-top">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indentation error in the entire file.

<div class="col-xs-12">
<div class="social">
<ul>
<div class="container-fluid">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why change content to container-fluid?

@@ -4,4 +4,5 @@
urlpatterns = [
url(r'^admin/', admin.site.urls),
url(r'', include('main.urls')),
url(r'^accounts/', include('registration.backends.simple.urls')),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're using the simple backend and you've created the files (email related) for the default backend. You should include registration.backends.default.urls.

@vaibhavsingh97
Copy link
Member Author

@jarifibrahim Thanks for reviewing. Can you please tell me the error?
Can we move to Slack for some discussion?

@vaibhavsingh97
Copy link
Member Author

@jarifibrahim Updated the suggested changes. Please review again

Copy link
Member

@jarifibrahim jarifibrahim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The login/registration isn't working. Does it work on your machine?
Also, you might want to squash your commits into a single commit. Ping me on slack if you don't know how to do it.

body {
overflow-x: hidden;
padding-top: 50px;
margin-bottom: 120px;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change breaks the layout. You might want to remove it.

@@ -52,25 +66,25 @@
<a href="https://www.youtube.com/channel/UC1_IAby-9me3iICtxuiDL5Q"><i class="fa fa-youtube-play" aria-hidden="true"></i></a>
</li>
</span>
<span class="col-sm-6 backToTop right-align">
<span class="col-sm-6 back-to-top right-align">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indentation error.

@@ -44,17 +49,31 @@ a {
border-color: #24292e;
}

.container-fluid {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally, it is a bad idea to apply styles to bootstrap classes. What if container-fluid is used somewhere else on the same page? It will automatically get padding-left: 0px which is not the intended behavior. You should add your own class/id if you wish to tweak a bootstrap element.

<button type="submit"
class="btn btn-lg btn-primary btn-block">{% trans 'Submit' %}</button>
</div>

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary new line.

<script src="{% static "main/js/script.js"%}"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>
<script src="{% static " main/js/script.js " %}"></script>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change static " main/js/script.js " to static "main/js/script.js"

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vaibhavsingh97
Copy link
Member Author

vaibhavsingh97 commented Jun 29, 2017

@jarifibrahim
capture1

@vaibhavsingh97
Copy link
Member Author

vaibhavsingh97 commented Jun 30, 2017

@tapasweni-pathak Please review and merge.
Steps to run this PR:

  • python manage.py migrate
  • python manage.py collectstatic
  • python manage.py runserver

@nikhita
Copy link
Contributor

nikhita commented Jul 1, 2017

Thanks for the instructions, @vaibhavsingh97! I checked the changes locally and it works perfectly. 🙌

@jarifibrahim @tapasweni-pathak Since you reviewed the PR, I'll leave it to you to merge it.

@jarifibrahim
Copy link
Member

Merging this since we have 2 approvals. Well done @vaibhavsingh97

@jarifibrahim jarifibrahim merged commit 6ca6380 into OpenSourceHelpCommunity:develop Jul 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants